package com.fofia.iotweb.web.domain.models;

import com.mybatisflex.annotation.Column;
import com.mybatisflex.annotation.Id;
import com.mybatisflex.annotation.KeyType;
import com.mybatisflex.annotation.Table;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.noear.snack.annotation.ONodeAttr;

import java.io.Serializable;
import java.util.Date;


@Data
@AllArgsConstructor
@NoArgsConstructor
@Table(value = "iot_gateways")
public class IotGateway implements Serializable {
    private static final long serialVersionUID = 1L;

    /**
     * 数据id
     */
    @Column(value = "upload_time")
    @ONodeAttr(name = "upload_time")
    private Date uploadTime;

    /**
     * 网关id
     */
    @Column(value = "externalPower")
    @ONodeAttr(name = "externalPower")
    private int externalPower;
    /**
     * 网关id
     */
    @Column(value = "voltage")
    @ONodeAttr(name = "voltage")
    private int voltage;

    @Column(value = "signal4g")
    @ONodeAttr(name = "signal4g")
    private int signal4g;

    @Column(value = "net4g")
    @ONodeAttr(name = "net4g")
    private int net4g;

    @Column(ignore = true)
    @ONodeAttr(name = "gatewayId")
    private String gatewayId;
}
